import java.util.*;


class Select{
	public String name;
	public byte age;
	public char sex;
	private Scanner sc = new Scanner(System.in);

	Select(){
		selectInfo();
	}

	public void selectInfo(){
		System.out.printf("Please input keyword to select: ");
		String str = sc.next();
		for (int i = 0; i < Add.info.size(); i++){
			Student stu = Add.info.get(i);
			if (str.equals("".valueOf(stu.getId())) || 
				str.equals("".valueOf(stu.getName())) || 
				str.equals("".valueOf(stu.getAge())) || 
				str.equals("".valueOf(stu.getSex())) ){
				System.out.printf("%8d  %8d  %8s  %4d  %4c\n\n",i,stu.getId(),stu.getName(),stu.getAge(),stu.getSex());
			}
		}
	}
}
